package Lee_code;

import java.util.Arrays;

/**
 * @author blh
 * @date 2024年07月31日 16:09
 */
public class Lee_673_731 {
    public int findNumberOfLIS(int[] nums) {
        int len = nums.length;
        int[] dp = new int[len];
        Arrays.fill(dp, 1);
        for (int i = 1; i < len; i++) {
            for (int j = 0; j < i; j++) {
                if (nums[i] > nums[j]) {
                    dp[i] = Math.max(dp[i], dp[j] + 1);
                }
            }
        }
        int max = Arrays.stream(dp).max().getAsInt();
        int[] count = new int[len];
        return count[len-1];
    }
}
